<%= form_for(@part) do |f| %>
  <% if @part.errors.any? %>
    <div id="error_explanation">
      <h2><%= pluralize(@part.errors.count, "error") %> prohibited this part from being saved:</h2>

      <ul>
      <% @part.errors.full_messages.each do |msg| %>
        <li><%= msg %></li>
      <% end %>
      </ul>
    </div>
  <% end %>
  
  <%= f.select :parts_group_id,  PartsGroup.all.collect {|p| [ p.name, p.id ] }, {:include_blank => ''} %>

  <div class="field">
    <%= f.label :name %><br />
    <%= f.text_field :name %>
  </div>
  <div class="actions">
    <%= f.submit %>
  </div>
<% end %>
